package com.qf.agro.controller;

import com.qf.agro.common.ResultInfo;
import com.qf.agro.service.DeviceTypeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author 10202
 * @version V1.0
 * @Project smart-agriculture-parent
 * @Package com.qf.agro.controller
 * @Date 2023/7/4 14:08
 */
@RestController
@RequestMapping("/device/type")
public class DeviceController {

    @Autowired
    private DeviceTypeService deviceTypeService;

    @GetMapping("/page")
    public ResultInfo devicePage(Long page,Long pageSize,String name){
        return deviceTypeService.devicePage(page,pageSize,name);
    }

    @GetMapping("/selectOptions")
    public ResultInfo getOptions(){
        return deviceTypeService.getOptions();
    }
}
